//
//  ProfileView.swift
//  TanTan_Kotlin
//
//  Created by EDY on 5/23/25.
//

import SwiftUI

struct ProfileView :View {
    var body: some View {
        VStack(alignment: .leading){
            HStack {
                Image(systemName: "person.circle.fill")
                    .resizable()
                    .frame(width: 100, height: 100)
                    .foregroundColor(.blue)
                VStack(alignment: .leading) {
                    Text("LYH")
                        .font(.title)
                        .foregroundColor(.primary)
                    Text("Developer")
                        .font(.subheadline)
                        .foregroundColor(.secondary)
                }
                .padding(.leading, 10)
            }
            .padding()
            Divider()
            VStack(alignment: .leading){
                Text("简介")
                    .font(.headline)
                Text("具有多年开发经验，熟悉Swift和SwiftUI,擅长构建高性能的应用程序。")
                    .font(.body)
                    .padding(.top, 5)
            }
            .padding()
            Spacer()
            Button(action: {
                print("Action Button")
            }){
                Text("联系方式：XXXXXXX")
                    .font(.title2)
                    .padding()
                    .background(Color.blue)
                    .foregroundColor(.white)
                    .cornerRadius(10)
                    .padding(.bottom, 20)
            }
            .frame(maxWidth:.infinity)
        }
        .padding()
        .background(Color(.systemGray6))
        .cornerRadius(15)
        .shadow(radius: 10)
        .padding()
    }
}

struct ProfileView_Previews: PreviewProvider {
    static var previews: some View{
        ProfileView()
    }
}
